package com.woniuxy.woniumall.mapper;

import com.woniuxy.woniumall.entity.Address;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface AddressMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(Address record);

    Address selectByPrimaryKey(Integer id);

    List<Address> selectAll();

    int updateByPrimaryKey(Address record);

    @Select("select * from t_address where user_id = #{id} and status = 1")
    List<Address> selectMyAdderss(Integer id);
}